Draft
Conversation
- Task 1: Project scaffolding (package.json, tsconfig.json, .gitignore)
- Task 2: Config & state management (src/config.ts, src/state.ts)
- Task 3: GitHub API tools (src/tools/{list-prs,get-pr-diff,create-draft-pr}.ts)
- Task 4: Skills context loader (src/skills.ts)
- Task 5: System prompt (prompts/system.md)
- Task 6: Agent orchestrator (src/index.ts) using getModel + Agent from pi-agent-core
- Task 7: README.md with setup/run/architecture docs
- Task 8: Unit tests (src/tools/list-prs.test.ts, vitest.config.ts)
- create-draft-pr: re-throw non-422 errors instead of swallowing all - create-draft-pr: accept explicit base branch param (removes extra API call) - list-prs: add pagination with early-exit (was silently missing >50 PRs) - skills: use recursive readdirSync to pick up nested skill files - state: rename getSince -> getEffectiveSince for clarity - index: remove redundant waitForIdle(), tighten user prompt to one line - index: pass BASE_BRANCH env var to create-draft-pr tool - tsconfig: switch module/moduleResolution to ESNext/Bundler for vitest compat - .env.example: document GEMINI_API_KEY and BASE_BRANCH
- eslint.config.js: use tsconfig.eslint.json, add argsIgnorePattern ^_ for unused params - tsconfig.eslint.json: new — extends tsconfig.json, includes test files - config.ts: remove unused fs import - index.ts: add Promise<void> return type, drop unused _provider name, String() for number in template - skills.ts: replace parentPath/any hack with explicit typed recursive walker - create-draft-pr.ts: String() for number in template, drop unused _signal name - get-pr-diff.ts: drop unused _signal name - list-prs.ts: extract PrRecord type alias (T[] not Array<T>), drop unused execute param names
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Goal: Build a Level-1 autonomous agent using
@mariozechner/pi-agent-core+@mariozechner/pi-aithat fetches GitHub PR diffs since its last run, synthesizes them with local skill docs, and opens a draft PR with prioritised refactoring suggestions.